package juint;

import org.junit.jupiter.api.Assertions;
import org.junit.jupiter.params.ParameterizedTest;
import org.junit.jupiter.params.provider.ValueSource;

/**
 * @Author quan
 * @Description 断言
 * @Date 2023/6/3 20:40
 */
public class Demo8_assert1 {
    @ParameterizedTest
    @ValueSource(ints = {10})
    void Test(int num){
        //断言相等
        Assertions.assertEquals(num,10);
        //断言不为空
        Assertions.assertNotNull(num);
        //断言不相等
//        Assertions.assertNotEquals(num,10);//报错
        //断言为空
//        Assertions.assertNull(num);//报错
    }
}
